<template>
  <div  class="container" style="height:100vh;overflow:auto">
  </div>
</template>
<style lang="less" scoped>

</style>
<script>
export default {
  components: {

  },
  methods: {
    getMsg: function(){
      let messageId = this.$route.query.messgaeId;
      this.post(Api.userApp.getMsg,{messageId:messageId},res=>{
        document.getElementsByClassName("container")[0].innerHTML = res.data.object[0].messageSubject;
        let imgList = document.getElementsByTagName('img');
        for(let i=0; i<imgList.length; i++){
          imgList[i].style.marginLeft = "0px";
          imgList[i].style.marginRight = "0px";
          if(imgList[i].width>document.body.clientWidth){
            imgList[i].style.width = '100%';
            imgList[i].style.height = 'auto';
          }
        }
      })
    }
  },
  mounted () {
    this.getMsg()
  },
  data () {
    return {

    }
  }
}
</script>



